package model

import (
	"gorm.io/gorm"
)

type ShorturlDao interface {
	GetList() (*[]Shorturl, error)
}
type defaultShorturlDao struct {
	engine *gorm.DB
}

func NewShorturlDao(engine *gorm.DB) *defaultShorturlDao {
	return &defaultShorturlDao{
		engine: engine,
	}
}

func (e *Shorturl) TableName() string {
	return "shorturl"
}
func (d defaultShorturlDao) GetList() (*[]Shorturl, error) {
	s := new([]Shorturl)
	var err error
	//这里写逻辑

	return s, err
}
